<template>
    <div>
        <Topbar class="top">365淘房-查房价</Topbar>
        <div class="main">
            <div class="msg">
                <img src="static/pic/icon_ershou.png" class="pic">
                <span>南京二手房价格信息</span>
            </div>
            <div class="msg1">
                <div class="msg1-left">
                    <span class="txt1">最新均价</span>
                    <span class="txt2"> 27179元/㎡</span>
                </div>
                <div  class="msg1-right">
                    <span class="txt1">环比上月</span>
                    <span class="fa fa-arrow-down txt1">0.08%</span>
                </div>
            </div>
            <div class="araeprice">区域房价</div>
            <div v-for="h in houseprice" class="pricelist">
                <div  class="txt1">{{h.title}}</div>
                <div class="txt1">{{h.price}}</div>
                <div>
                    <span class="up">{{h.up}}</span>
                    <span class="txt1">{{h.num}}</span>
                    <span class="fa fa-angle-right"></span>
                </div>
            </div>

            <!--评估我的房子-->
            <div class="myhouse">
                <div>
                    <span class="myhouse1">评估我的房子</span>
                </div>
            </div>
        </div>
    </div>
</template>

<script>
import Topbar from '../components/Topbar.vue'
import {mapState} from 'vuex'
    export default{
        components:{
            Topbar
        },
        computed:{
            ...mapState([
               "houseprice"
           ]),
        }
    }
</script>

<style scoped>
.top{
    position: fixed;
    width: 100%;
}
.main{
    height: 100vh;
    overflow-y: scroll;
    padding-top: 41px;
}
.msg{
    padding: 8px;
    border: 1px solid #eeeeee;
}
.msg1{
    display: flex;
    justify-content: space-between;
    height: 44px;
    line-height: 44px;
    border-bottom: 1px solid #eeeeee;
}
.msg1-left{
    margin-left: 8px;
}
.msg1-right{
    margin-right: 8px;
}
.txt1{
    font-size: 12px;
}

.txt2{
    font-size: 16px;
    color: #F39300;
}
.pic{
    height: 22px;
    width: 22px;
    vertical-align: middle;
}
.araeprice{
    padding-top: 20px;
    padding-bottom: 10px;
    padding-left: 8px;
    border-bottom: 1px solid #eeeeee;
}
.pricelist{
    display: flex;
    justify-content: space-around;
}
.pricelist div{
    height: 36px;
    line-height: 36px;
}
.pricelist:hover{
    color: #F39300;
}
.up{
    font-size: 14px;
    color: lightgreen;
}
.down{
    font-size: 14px;
    color: #F39300;
}
.myhouse{
    width: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    height: 60px;
    text-align: center;
    position: fixed;
    bottom: 0;
}
.myhouse1{
    display: inline-block;
    /*width: 40%;
    height: 30px;*/
    padding: 4px 10px;
    border-radius: 4px;
    margin-top: 15px;
    background-color: #F39300;
    font-size: 14px;
    color: white;
}
</style>